
// dbDlg.h : header file
//

#pragma once
#include "afxwin.h"
#include "db_api.h"

#define WM_DB_CALLBACK	WM_USER + 0x100


// CdbDlg dialog
class CdbDlg : public CDialogEx
{
// Construction
public:
	CdbDlg(CWnd* pParent = NULL);	// standard constructor

// Dialog Data
	enum { IDD = IDD_DB_DIALOG };

	protected:
	virtual void DoDataExchange(CDataExchange* pDX);	// DDX/DDV support
	void ShowSelectResult(RECORD records[20], int nTotal);
	void ShowSelectItems(RECITEMUTF8 items[20], int nTotal);
	CString Utf8ToWideChar(char * txt);
	CStringA WideCharToUtf8(CString str);
	
	void OfflineTest();

// Implementation
protected:
	HICON m_hIcon;
	CComboBox m_ComboType;
	int m_type;
	CString m_dir;
	CString m_album;
	CString m_artist;
	int m_like;
	int m_offset;

	// Generated message map functions
	virtual void OnOK();
	virtual void OnCancel();
	virtual BOOL OnInitDialog();
	afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
	afx_msg void OnPaint();
	afx_msg HCURSOR OnQueryDragIcon();
	DECLARE_MESSAGE_MAP()
public:
	afx_msg LRESULT OnDBCallback(WPARAM, LPARAM);
	afx_msg void OnBnClickedButton1();
	afx_msg void OnBnClickedRadio1();
	afx_msg void OnBnClickedRadio2();
	afx_msg void OnBnClickedRadio3();
	afx_msg void OnBnClickedRadio4();
	afx_msg void OnBnClickedRadio5();
	afx_msg void OnBnClickedRadio6();
	afx_msg void OnBnClickedRadio7();
	afx_msg void OnBnClickedRadio8();
	afx_msg void OnBnClickedRadio9();
	afx_msg void OnBnClickedRadio10();
	afx_msg void OnBnClickedRadio11();
	afx_msg void OnBnClickedRadio12();
	afx_msg void OnBnClickedRadio13();
	afx_msg void OnBnClickedRadio14();
	afx_msg void OnBnClickedRadio15();
	afx_msg void OnBnClickedRadio16();
	afx_msg void OnBnClickedRadio17();
};
